﻿using System.Collections;
using System.Text;
using SimpleJSON;
using ROSBridgeLib.std_msgs;
using UnityEngine;

namespace ROSBridgeLib {
    namespace geometry_msgs {
        public class PoseMsg : ROSBridgeMsg {


            public Vector3Msg position;

            public Vector4Msg orientation;

            public PoseMsg(){
                
                position=new Vector3Msg();

                orientation=new Vector4Msg();

            }

            public PoseMsg(JSONNode msg) {
               

                position=new Vector3Msg(msg["position"]);

               
                orientation=new Vector4Msg(msg["orientation"]);


            }


            public override string ToYAMLString() {

                return "{\"position\" : "+position.ToYAMLString()  +", \"orientation\" : " + orientation.ToYAMLString() + "}";
            } 
           
        }
    }
}